﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="loainhanvien.aspx.cs" Inherits="Admin_loainhanvien" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
    <style type="text/css">
        .style1
        {
            width: 162px;
        }

.icsa, .ica
{
	background-image:url(../Images/Testing/plus_16.png);
}

.ice, .icd, .ics, .icc, .ica, .icm, .icf, .ict, .icb, .icn, .ick, .icp, .icl, .ici, .icu
{
	padding-left:22px;
	padding-top:1px;
	padding-bottom:1px;
	padding-right:3px;
	font-weight:bold;
	background-repeat:no-repeat;
	background-position: 5px center;
}

        .style2
        {
            width: 461px;
        }
        .style3
        {
            width: 162px;
            height: 33px;
        }
        .style4
        {
            width: 461px;
            height: 33px;
            text-align: left;
        }
        .style5
        {
            height: 33px;
        }
    </style>
    <link href="../CSS/style.css" rel="stylesheet" type="text/css" />
</head>
<body>
    <form id="form1" runat="server">
    <table style="width:100%;">
        <tr>
            <td class="style3">
                &nbsp;</td>
            <td class="style4">
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
            <td class="style5">
            </td>
        </tr>
        <tr>
            <td class="style1">
                <asp:Label ID="lbtenloainhanvien" runat="server" Text="Tên Loại Nhân Viên"></asp:Label>
            </td>
            <td class="style2">
                &nbsp;&nbsp;&nbsp;
                <asp:TextBox ID="txttenloainhanvien" runat="server" style="text-align: left"></asp:TextBox>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                    <asp:Button ID="btnthem" runat="server" CssClass="ica" Text="Thêm" 
                        onclick="btnthem_Click" ValidationGroup="reg" />
                    &nbsp;<asp:Button ID="btnboqua" runat="server" CssClass="icc" Text="Bỏ qua" 
                        onclick="btnboqua_Click" />
                </td>
            <td>
                &nbsp;</td>
        </tr>
        <tr>
            <td class="style1">
                &nbsp;</td>
            <td class="style2">
                &nbsp;</td>
            <td>
                &nbsp;</td>
        </tr>
    </table>
                    <asp:GridView ID="grvds" runat="server" AutoGenerateColumns="False" 
                        DataSourceID="loainhanvien" 
        meta:resourcekey="grvdsResource1" Width="100%" 
                        EnableModelValidation="True">
                        <Columns>
                            <asp:TemplateField HeaderText="STT" meta:resourcekey="TemplateFieldResource1">
                                <ItemStyle HorizontalAlign="Center" Width="3%" />
                                <ItemTemplate>
                                    <%#Container.DataItemIndex+1 %>
                                </ItemTemplate>
                            </asp:TemplateField>
                            <asp:TemplateField HeaderText="Tên Loại nhân viên">
                                <ItemTemplate>
                                    <asp:Label ID="lbloainv" runat="server" 
                                        Text='<%# Eval("id_row") %>' Visible="False"></asp:Label>
                                
                                    <asp:Label ID="lbtenloainhanvien" runat="server" 
                                        Text='<%# Eval("tenloainv") %>'></asp:Label>
                                </ItemTemplate>
                            </asp:TemplateField>
                            <asp:TemplateField >
                                <ItemTemplate>
                                    <asp:ImageButton ID="imgsua" runat="server" 
                                        CommandArgument='<%# Eval("id_row") %>' 
                                        ImageUrl="~/Images/Testing/pencil_16.png" 
                                        onclick="imgsua_Click" ToolTip="Sửa" />
                                    <asp:ImageButton ID="imgxoa" runat="server" 
                                        CommandArgument='<%# Eval("id_row") %>' 
                                        ImageUrl="~/Images/Testing/delete_16.png"
                                        onclick="imgxoa_Click" onclientclick="return confirm('Bạn có chắc muốn xóa?')" 
                                        ToolTip="Xóa" />
                                
                                </ItemTemplate>

<ItemStyle HorizontalAlign="Center" Width="7%"></ItemStyle>
                            </asp:TemplateField>
                        </Columns>
                    </asp:GridView>
                    <asp:SqlDataSource ID="loainhanvien" runat="server" 
        ConnectionString="<%$ ConnectionStrings:ConnectionString %>" 
               SelectCommand="SELECT * FROM [Loainhanvien]"></asp:SqlDataSource>
    <asp:Label ID="lbid" runat="server"></asp:Label>
    </form>
</body>
</html>
